<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<div th:inline="text">
    <span>[[${name}]]</span>
</div>
</body>
<script type="text/javascript" th:inline="javascpript">
    alert([[${name}]])
</script>
</html>